package com.isp.org.server.interfaces.model.menu.vo;

import com.fasterxml.jackson.annotation.JsonProperty;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

/**
 * @author linsy
 * @version 1.0
 * @created 2024/1/26 09:21
 */
@Data
public class BaseMenuVO {

    @ApiModelProperty("父节点ID")
    @JsonProperty("parent_id")
    @NotNull(message = "父菜单不能为空")
    private Long parentId;
    @ApiModelProperty("code")
    @JsonProperty("code")
    @NotBlank(message = "菜单code不能为空")
    private String code;
    @ApiModelProperty("样式")
    @JsonProperty("icon")
    private String icon;
    @ApiModelProperty("请求后端url")
    @JsonProperty("url")
    private String url;
    @ApiModelProperty("菜单path")
    @JsonProperty("path")
    private String path;
    @ApiModelProperty("排序")
    @JsonProperty("sort")
    @NotNull(message = "排序不能为空")
    private Integer sort;
    @ApiModelProperty("菜单类型")
    @JsonProperty("type")
    @NotNull(message = "菜单类型不能为空")
    private Integer type;
    @ApiModelProperty("是否隐藏")
    @JsonProperty("hidden")
    @NotNull(message = "是否隐藏菜单不能为空")
    private Boolean hidden;
    @ApiModelProperty("请求方法")
    @JsonProperty("url_method")
    private String urlMethod;
    @ApiModelProperty("应用")
    @JsonProperty("app")
    @NotBlank(message = "app不能为空")
    private String app;
    @ApiModelProperty("组件")
    @JsonProperty("component")
    private String component;
    @ApiModelProperty("外链")
    @JsonProperty("href")
    private String href;
    @ApiModelProperty("i18n标题")
    @JsonProperty("i18n_title")
    private String i18nTitle;
    @ApiModelProperty("标题")
    @JsonProperty("title")
    private String title;

}
